package acn.spring.backend.springDataJpa;

import java.util.List;

import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.stereotype.Repository;

import acn.spring.domain.Customer;
import acn.spring.domain.Order;
import acn.spring.domain.OrderStatus;

@Repository
public interface OrderRepository extends JpaRepository<Order, Long> {

	List<Order> findByCustomer(Customer customer);

	List<Order> findByCustomerAndStatus(Customer customer, OrderStatus status);
}
